Title Banner

Previous Book Contents Book Index Next

Inside Macintosh: QuickDraw GX Graphics /
Chapter 4 - Geometric Operations / Geometric Operations Reference
Functions / Determining and Reversing Contour Direction


GXReverseShape

You can use the GXReverseShape function to reverse the order of the geometric points in a shape's contour.

void GXReverseShape(gxShape target, long contour);
target
A reference to the shape containing the contour.
contour
The number of the contour you want to reverse. You may specify a value of 0 for this parameter to indicate all contours.
DESCRIPTION
The GXReverseShape function reverses the order of the geometric points of the contour specified by the contour parameter in the shape specified by the target parameter.

If you specify a value of 0 for the contour parameter, this function reverses the order of the geometric points in each contour of the target shape, but does not affect the order of the contours themselves. If the target shape is a rectangle shape, this function converts it to a polygon shape before reversing the direction.

You can use this function to control how QuickDraw GX

If you provide a target shape that is not one of the geometric shape types, this function performs the actions described in the following table:
Shape typeAction taken
bitmapPosts the error illegal_type_for_shape
picturePosts the error illegal_type_for_shape
textPosts the error illegal_type_for_shape
glyphPosts the error illegal_type_for_shape
layoutPosts the error illegal_type_for_shape

ERRORS, WARNINGS, AND NOTICES
Errors 
out_of_memory 
shape_is_nil 
contour_is_less_than_zero(debugging version)
illegal_type_for_shape(debugging version)
Warnings 
contour_out_of_range 
shape_access_not_allowed 
SEE ALSO
For examples using this function, see "Determining and Reversing Contour Direction" beginning on page 4-23.

To determine the direction of a contour, use the GXGetShapeDirection function, described on page 4-68.

For a discussion of geometric points, see the Chapter 2, "Geometric Shapes."

For a discussion of contour direction, see "Contours and Contour Direction" beginning on page 4-4.

For a discussion of dashes and the gxInsideFrameStyle or gxOutsideFrameStyle style attributes, see the Chapter 3, "Geometric Styles," in this book.

For a description of the GXInsetShape function, see page 4-94.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996




Navigation graphic, see text links

Main | Page One | What's New | Apple Computer, Inc. | Find It | Contact Us | Help